Safer and faster string sorting
authorMattias Engdegård <mattiase@acm.org>
Sun, 12 May 2024 09:22:23 +0000 (11:22 +0200)
committerMattias Engdegård <mattiase@acm.org>
Sun, 12 May 2024 12:58:38 +0000 (14:58 +0200)
commit38091e43bee991920db81263fe56da444a123fae
treef6acb504bad0afa452ca7ee89c7f0afbd37ecc17
parent86d196c71d763ae81229e7e1eb2c6e37d0456f06
Safer and faster string sorting

* lisp/emacs-lisp/cl-seq.el (cl-sort):
Don't use string mutation when sorting the characters in a string.
This avoids O(n^2) run time and makes it future-safe.
lisp/emacs-lisp/cl-seq.el